import { NgModule } from '@angular/core';
import { HTTP_INTERCEPTORS } from '@angular/common/http';
import { UrlInterceptor } from './interceptor/url-interceptor';

@NgModule({
  imports: [
  ],
  providers: [
    // { provide: HTTP_INTERCEPTORS, useClass: AuthInterceptor, multi: true }, // 权限拦截器
    { provide: HTTP_INTERCEPTORS, useClass: UrlInterceptor, multi: true },  // url路径拦截器 配置base url
    // { provide: HTTP_INTERCEPTORS, useClass: MethodInterceptor, multi: true }, // 拦截请求头 对特定的method进行处理
    // { provide: HTTP_INTERCEPTORS, useClass: ErrorInterceptor, multi: true },  // 错误拦截器
    // AuthGuard,
    // CookieService,
    // LocalService
  ],
  declarations: [ ],
  exports: [ ]
})
export class ServiceModule { }